/**
 * 郭楠project
 * com.gn.serviceImpl
 * UserMessageServiceImpl.java
 * 创建人:TonyGuo 
 * 时间：2016年12月12日-下午10:20:43 
 * 2016Tm公司-版权所有
 */
package com.gn.serviceImpl;

import java.util.List;

import javax.annotation.Resource;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;

import com.gn.controller.UserMessageController;
import com.gn.dao.UserMessageDao;
import com.gn.entity.UserMessage;
import com.gn.service.UserMessageService;

/**
 * 
 * UserMessageServiceImpl
 * 创建人:TonyGuo
 * 时间：2016年12月12日-下午10:20:43 
 * @version 1.0.0
 * 
 */
@Service
public class UserMessageServiceImpl implements UserMessageService{
	private Logger logger=LoggerFactory.getLogger(UserMessageServiceImpl.class);
	
	@Resource
	UserMessageDao userMessageDao;

	@Override
	public void addUserMessage(UserMessage userMessage) {
		userMessageDao.addUserMessage(userMessage);
	}

	@Override
	public void deleteUserMessage(String id) {
		userMessageDao.deleteUserMessage(id);
	}

	@Override
	public UserMessage findUserMessage(String id) {
		return userMessageDao.findUserMessage(id);
	}

	@Override
	public List<UserMessage> findUserMessageList(String uid) {
		return userMessageDao.findUserMessageList(uid);
	}

	@Override
	public List<UserMessage> findAllUserMessages() {
		return userMessageDao.findAllUserMessages();
	}

	@Override
	public boolean replyContentUpdate(String isReply, String replyContent, String replyTime, String id) {
		logger.info("isReply:{},replyContent:{},replyTime：{},id:{}",new Object[]{isReply, replyContent,replyTime,id});
		return userMessageDao.replyContentUpdate(isReply, replyContent, replyTime,id);
	}

}
